#!/usr/bin/env python3
# -*- coding: utf-8 -*-

class Student(object):

    _hobby = 'eat'
    __skill = 'program'

    def __init__(self, name, age):
        self.name = name
        self.age = age

    def print_info(self):
        print('name: %s age: %d' % (self.name, self.age))

    def print_age(self):
        if self.age <= 18:
            print('you look young')
        elif self.age <= 24:
            print('you look not bad')
        else:
            print('lao bi')
    
    def set_private(self, hobby, skill):
        self._hobby = hobby
        self.__skill = skill


    def get_private(self):
        print('protected hobby %s' % self._hobby)
        print('private skill %s' % self.__skill)

jingks = Student('jingks', 26)
jingks.print_info()
jingks.print_age()
jingks.get_private()
print(jingks._hobby)
print(jingks._Student__skill)
jingks.set_private('play', 'strong')
jingks.get_private()